package com.crhms.seabow.controller;

import com.crhms.seabow.entity.Lesson;
import com.crhms.seabow.service.LessonService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/lesson")
public class LessonController {

    @Autowired
    private LessonService lessonService;

    @RequestMapping("/getLessons")
    public List<Lesson> getLessons() {
        return  lessonService.getLessons();
    }
}
